Skip to content

010: Log rotation feature#32

Merged
grobomo merged 1 commit intomainfrom
010-add-logrotate
Mar 31, 2026
Merged

010: Log rotation feature#32
grobomo merged 1 commit intomainfrom
010-add-logrotate

Conversation

@grobomo
Copy link
Copy Markdown
Owner

@grobomo grobomo commented Mar 31, 2026

Summary

  • T033: Size-based log rotation via core/logrotate.py
  • Prevents unbounded coconut.log growth in long-running deployments
  • 5 new tests, all existing tests still pass

Test plan

  • bash scripts/test/test-logrotate.sh (5/5 passing)

RotatingLog replaces raw file open — rotates coconut.log at configurable
size threshold (default 5MB), keeps N backup files (.log.1, .log.2, ...).
Config via COCONUT_LOG_MAX_BYTES and COCONUT_LOG_BACKUPS env vars.
5 tests passing.

Co-authored-by: grobomo <grobomo@users.noreply.github.com>
@grobomo grobomo merged commit 9499421 into main Mar 31, 2026
2 checks passed
@grobomo grobomo deleted the 010-add-logrotate branch March 31, 2026 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant